﻿using LeRenard.ScriptWars.Model.Entities;
using LeRenard.ScriptWars.Model.Scripting.Definitions;
using System;
using System.Collections.Generic;

namespace LeRenard.ScriptWars.Model.Scripting
{
    /// <summary>
    /// Defines a concrete operation.
    /// </summary>
    public interface IOperation
    {
        /// <summary>
        /// Gets the line number the operation is defined on.
        /// </summary>
        int LineNumber { get; }

        /// <summary>
        /// Gets the associated definition of the operation.
        /// </summary>
        IOperationDefinition Definition { get; }

        /// <summary>
        /// Gets the parameters of the parameter, if any.
        /// </summary>
        IEnumerable<IOperationParameter> Parameters { get; }        

        /// <summary>
        /// Executes the operation.
        /// </summary>        
        void Execute(IEntity entity, IAlgorithmCycler algorithmCycler, IGame game);        
    }
}
